﻿<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>页面的地震效果</title>
    <script type="text/javascript" language="JavaScript">
        function shake(n){
            if(window.top.moveBy){
                for(i = 10;i > 0;i--){
                    for(j = n;j > 0;j--){
                        window.top.moveBy(0,i);
                        window.top.moveBy(i,0);
                        window.top.moveBy(0,-i);
                        window.top.moveBy(-i,0);
                    }
                }
            }
            alert("短时间的地震已经过去，您可以安全工作了");
        }
    </script>
</head>
<body onload="shake(50)">

</body>
</html>